Stores control settings.
Type | Member Name | Description | Default Value |
---|---|---|---|
Double | Timeout | Timeout period (1 to 9999 seconds) | 5 |
Double | Wait | Wait before transmission (0 to 9999 seconds) | 0 |
Int32 | RepeatNum | Number of repetitions (0 to 9999 times) | 1 |
Stores option settings.
Type | Member Name | Description | Default Value |
---|---|---|---|
Boolean | SendCheck | Check before sending (true:Confirm, false:Don’t confirm) | false |
Boolean | NotOverWriteMsg | No overwrite message (true:Don’t show, false:Show) | false |
Boolean | NotEndMsg | No end message (true:Don’t show, false:Show) | false |
Boolean | TimeLog | Output time stamp (true:Output, false:Don’t output) | false |
Boolean | CommTimeLog | Output communication time (true:Output, false:Don’t output) | false |
Boolean | OverWrite | Overwrite with repeat (true:Output, false:Don’t output) | false |
Boolean | SeparateComma | Split by COMMA and SEMICOLON (true:Split, false:Don’t split) | false |
String | ExponentFormat | Exponential display format | "###.0#########E+00" |
String | LineAccessToken | LINE access token | "" |
Stores interface settings.
Type | Member Name | Description | Default Value |
---|---|---|---|
Int32 | InterfaceType | Interface (0:Not used, 1:RS-232C/USB, 2:LAN, 3:GPIB(NI), 4:GPIB(CONTEC), 5:VISA) | 0 |
Int32 | Terminator | Transmit terminator (0:None, 1:CR+LF, 2:CR, 3:LF) | 1 |
Int32 | Charset | Charset (0:ASCII, 1:UTF-8, 2:Shift-JIS) | 0 |
String | RsComPort | RS-232C/USB COM Port | "" |
Int32 | RsSpeed | RS-232C/USB Speed (4800, 9600, 14400, 19200, 38400, 57600, 115200) | 9600 |
Int32 | RsData | RS-232C/USB Data (0:7bit, 1:8bit) | 1 |
Int32 | RsParity | RS-232C/USB Parity (0:None, 1:Odd, 2:Even) | 0 |
Int32 | RsStopBits | RS-232C/USB Stop bits (0:1bit, 1:2bit) | 0 |
Boolean | RsFlowXon | RS-232C/USB Flow control Xon/Xoff (true:On, false:Off) | false |
Boolean | RsFlowRts | RS-232C/USB Flow control RTS/CTS (true:On, false:Off) | true |
Boolean | RsFlowDsr | RS-232C/USB Flow control DSR/DTR (true:On, false:Off) | true |
String | LanIp | LAN IP address | "192.168.1.1" |
Int32 | LanPort | LAN Port | 6866 |
Int32 | GpibNiBoardId | GPIB(NI) Board ID (0 to 99) | 0 |
Int32 | GpibNiAddress | GPIB(NI) Address (0 to 30) | 1 |
Boolean | GpibNiDcl | GPIB(NI) Device clear when connected (true:Clear, false:Don’t clear) | true |
Boolean | GpibNiEoi | GPIB(NI) Use EOI (true:Use, false:Don’t use) | true |
Int32 | GpibContecBoardId | GPIB(CONTEC) Driver No. (1 to 4) | 1 |
Int32 | GpibContecAddress | GPIB(CONTEC) Address (0 to 30) | 1 |
Boolean | GpibContecDcl | GPIB(CONTEC) Device clear when connected (true:Clear, false:Don’t clear) | true |
Boolean | GpibContecEoi | GPIB(CONTEC) Use EOI (true:Use, false:Don’t use) | true |
String | VisaAddress | VISA Address | "" |
Boolean | VisaEom | VISA Use EOM (true:Use, false:Don’t use) | false |
Stores all settings for Sequence Maker.
Type | Member Name | Description |
---|---|---|
ControlParameter | ControlParameter | Control settings |
OptionParameter | OptionParameter | Option settings |
InterfaceParameter[6] | InterfaceParameter | Interface settings |
It is not possible to access the InterfaceParameter array directly
from VBA.
Accessed via a reference obtained with the
SequenceMakerParameter.GetInterfaceParameter() method.
The argument
of the method is an array index (0 to 5).
Stores binary messages.
Type | Member Name | Description | Default Value |
---|---|---|---|
Byte[] | Data | Data | null |
Int32 | Length | Data Length | 0 |
Start sending/receiving.
Start(); Int32
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim result As Long
result = automationObject.Start()
If result <> 0 Then
Exit Sub
End If
This is the same function as clicking the Send Command
button on the Sequence Maker ribbon.
It does not return from the
method until the send/receive is complete.
Stop sending/receiving.
Stop(); Int32
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim result As Long
result = automationObject.Stop()
If result <> 0 Then
Exit Sub
End If
This is the same function as clicking the Stop
button on
the Sequence Maker ribbon.
The Start() method does not return from
the method until the send/receive is complete, so it is used when the
send/receive is started with the Send Command
button on the
ribbon.
Returns send/receive status.
GetStatus(); Int32
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim result As Long
result = automationObject.GetStatus()
Get control settings.
GetControlSetting(ref ControlParameter controlSetting); Int32
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim controlSetting As Variant
Set controlSetting = automationObject.CreateControlParameter()
Dim result As Long
result = automationObject.GetControlSetting(controlSetting)
If result <> 0 Then
Exit Sub
End If
Specify the instance created by the CreateControlParameter() method in the control settings argument.
Set control settings.
SetControlSetting(ControlParameter controlSetting); Int32
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim controlSetting As Variant
Set controlSetting = automationObject.CreateControlParameter()
Dim result As Long
controlSetting.Timeout = 5#
result = automationObject.SetControlSetting(controlSetting)
If result <> 0 Then
Exit Sub
End If
Specify the instance created by the CreateControlParameter() method in the control settings argument.
Get option settings.
GetOptionSetting(ref OptionParameter optionSetting); Int32
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim optionSetting As Variant
Set optionSetting = automationObject.CreateOptionParameter()
Dim result As Long
result = automationObject.GetOptionSetting(optionSetting)
If result <> 0 Then
Exit Sub
End If
Specify the instance created by the CreateOptionParameter() method in the option settings argument.
Set option settings.
SetOptionSetting(OptionParameter optionSetting); Int32
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim optionSetting As Variant
Set optionSetting = automationObject.CreateOptionParameter()
Dim result As Long
optionSetting.SendCheck = False
result = automationObject.SetOptionSetting(optionSetting)
If result <> 0 Then
Exit Sub
End If
Specify the instance created by the CreateOptionParameter() method in the option settings argument.
Get interface settings.
GetInterfaceSetting(ref InterfaceParameter interfaceSetting, Int32 interfaceNo); Int32
Interface No. (1 to 6)
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim interfaceSetting As Variant
Set interfaceSetting = automationObject.CreateInterfaceParameter()
Dim result As Long
result = automationObject.GetInterfaceSetting(interfaceSetting, 1)
If result <> 0 Then
Exit Sub
End If
Specify the instance created by the CreateInterfaceParameter() method in the interface settings argument.
Set interface settings.
SetInterfaceSetting(InterfaceParameter interfaceSetting, Int32 interfaceNo); Int32
Interface No. (1 to 6)
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim interfaceSetting As Variant
Set interfaceSetting = automationObject.CreateInterfaceParameter()
Dim result As Long
interfaceSetting.InterfaceType = 1
result = automationObject.SetInterfaceSetting(interfaceSetting, 1)
If result <> 0 Then
Exit Sub
End If
Specify the instance created by the CreateInterfaceParameter() method in the interface settings argument.
Get Sequence Maker settings.
GetSequenceMakerSetting(ref SequenceMakerParameter sequenceMakerSetting); Int32
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim sequenceMakerSetting As Variant
Set sequenceMakerSetting = automationObject.CreateSequenceMakerParameter()
Dim result As Long
result = automationObject.GetSequenceMakerSetting(sequenceMakerSetting)
If result <> 0 Then
Exit Sub
End If
Specify the instance created by the CreateSequenceMakerParameter() method in the Sequence Maker settings argument.
Set Sequence Maker settings.
SetSequenceMakerSetting(SequenceMakerParameter sequenceMakerSetting); Int32
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim sequenceMakerSetting As Variant
Set sequenceMakerSetting = automationObject.CreateSequenceMakerParameter()
Dim interfaceSetting As Variant
Dim result As Long
sequenceMakerSetting.ControlParameter.Timeout = 5#
sequenceMakerSetting.OptionParameter.SendCheck = False
Set interfaceSetting = sequenceMakerSetting.GetInterfaceParameter(0)
interfaceSetting.InterfaceType = 1
result = automationObject.SetSequenceMakerSetting(sequenceMakerSetting)
If result <> 0 Then
Exit Sub
End If
Specify the instance created by the CreateSequenceMakerParameter() method in the Sequence Maker settings argument.
Reading Sequence Maker settings from a file.
ReadSequenceMakerSetting(ref SequenceMakerParameter sequenceMakerSetting,
Int32 ); String pathname
Settings file name
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim sequenceMakerSetting As Variant
Set sequenceMakerSetting = automationObject.CreateSequenceMakerParameter()
Dim result As Long
result = automationObject.ReadSequenceMakerSetting(sequenceMakerSetting, "SequenceMaker.xml")
If result <> 0 Then
Exit Sub
End If
Specify the instance created by the CreateSequenceMakerParameter() method in the Sequence Maker settings argument.
Write Sequence Maker settings to a file.
WriteSequenceMakerSetting(SequenceMakerParameter sequenceMakerSetting,
Int32 ); String pathname
Settings file name
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim sequenceMakerSetting As Variant
Set sequenceMakerSetting = automationObject.CreateSequenceMakerParameter()
Dim result As Long
result = automationObject.WriteSequenceMakerSetting(sequenceMakerSetting, "SequenceMaker.xml")
If result <> 0 Then
Exit Sub
End If
Specify the instance created by the CreateSequenceMakerParameter() method in the Sequence Maker settings argument.
Create an instance of ControlParameter.
CreateControlParameter(); ControlParameter
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim controlSetting As Variant
Set controlSetting = automationObject.CreateControlParameter()
Create an instance of OptionParameter.
CreateOptionParameter(); OptionParameter
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim optionSetting As Variant
Set optionSetting = automationObject.CreateOptionParameter()
Create an instance of ControlParameter.
CreateInterfaceParameter(); InterfaceParameter
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim interfaceSetting As Variant
Set interfaceSetting = automationObject.CreateInterfaceParameter()
Create an instance of SequenceMakerParameter.
CreateSequenceMakerParameter(); SequenceMakerParameter
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim sequenceMakerSetting As Variant
Set sequenceMakerSetting = automationObject.CreateSequenceMakerParameter()
Create an instance of BinaryData.
CreateBinaryData(); BinaryData
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim binaryData As Variant
Set binaryData = automationObject.CreateBinaryData()
Open interface.
InterfaceOpen(Int32 interfaceNo); Int32
Interface No. (1 to 6)
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim result As Long
result = automationObject.InterfaceClose(1)
If result <> 0 Then
Exit Sub
End If
Close interface.
InterfaceClose(Int32 interfaceNo); Int32
Interface No. (1 to 6)
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim result As Long
result = automationObject.InterfaceOpen(1)
If result <> 0 Then
Exit Sub
End If
result = automationObject.InterfaceClose(1)
If result <> 0 Then
Exit Sub
End If
Send message.
SendMessage(Int32 interfaceNo, String sendMessage); Int32
Interface No. (1 to 6)
Message to send
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim result As Long
result = automationObject.InterfaceOpen(1)
If result <> 0 Then
Exit Sub
End If
result = automationObject.SendMessage(1, "*TRG")
If result <> 0 Then
Call automationObject.InterfaceClose(1)
Exit Sub
End If
result = automationObject.InterfaceClose(1)
If result <> 0 Then
Exit Sub
End If
Receive message.
ReceiveMessage(Int32 interfaceNo, ref String receiveMessage, Double timeout); Int32
Interface No. (1 to 6)
Received message
Timeout period (1 to 9999 seconds)
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim receiveMessage As String
Dim result As Long
result = automationObject.InterfaceOpen(1)
If result <> 0 Then
Exit Sub
End If
result = automationObject.ReceiveMessage(1, receiveMessage, 5#)
If result <> 0 Then
Call automationObject.InterfaceClose(1)
Exit Sub
End If
result = automationObject.InterfaceClose(1)
If result <> 0 Then
Exit Sub
End If
Send and receive message.
SendReceiveMessage(Int32 interfaceNo, String sendMessage,
Int32 ref String receiveMessage, Double timeout);
Interface No. (1 to 6)
Message to send
Received message
Timeout period (1 to 9999 seconds)
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim receiveMessage As String
Dim result As Long
result = automationObject.InterfaceOpen(1)
If result <> 0 Then
Exit Sub
End If
result = automationObject.SendReceiveMessage(1, ":MEASure?", receiveMessage, 5#)
If result <> 0 Then
Call automationObject.InterfaceClose(1)
Exit Sub
End If
result = automationObject.InterfaceClose(1)
If result <> 0 Then
Exit Sub
End If
Send and receive binary response message.
SendReceiveIeeeBinary(Int32 interfaceNo, String sendMessage,
Int32 ref BinaryData receiveMessage, Double timeout);
Interface No. (1 to 6)
Message to send
Timeout period (1 to 9999 seconds)
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim receiveMessage As Variant
Set receiveMessage = automationObject.CreateBinaryData()
Dim result As Long
result = automationObject.InterfaceOpen(1)
If result <> 0 Then
Exit Sub
End If
result = automationObject.SendReceiveIeeeBinary(1, ":HCOPy:DATA? COLor", receiveMessage, 10#)
If result <> 0 Then
Call automationObject.InterfaceClose(1)
Exit Sub
End If
result = automationObject.InterfaceClose(1)
If result <> 0 Then
Exit Sub
End If
Specify the instance created with the CreateBinaryData() method for the receive message argument.
Get COM Port names.
[] GetComPortName(); String
COM Port names
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim comPortName() As String
comPortName = automationObject.GetComPortName()
Get VISA Addresses.
[] GetVisaAddress(); String
VISA Addresses
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim visaAddress() As String
visaAddress = automationObject.GetVisaAddress()
Get Sequence Maker version number.
GetVersion(); String
Version number
Dim automationObject As Object
Set automationObject = Application.COMAddIns("Sequence Maker").Object
Dim version As String
version = automationObject.GetVersion()
Value | Description |
---|---|
0 | Success. |
1 | Sending/Receiving. |
2 | Stopped. |
3 | Argument type is wrong. |
4 | Interface No. is out of range. |
5 | Interface is opened. |
6 | Interface is closed. |
7 | Driver is not installed. |
8 | Driver version is out of date. |
9 | Interface not selected. |
10 | Interface open failed. |
11 | Timeout period is out of range. |
12 | Send/Receive failure. |
13 | File does not exist. |
14 | File access failure. |
Sequence Maker
Dim addIn As COMAddIn
Dim automationObject As Object
Set addIn = Application.COMAddIns("Sequence Maker")
Set automationObject = addIn.Object